package lincen.javame.light.ui.geometric;


/**
 * ������
 * �ڲ�����Ϣ�������εĺ����,�����,���,�߶�
 * @author ���
 */
public class Rect {

	/**
	 * ���ε����
	 */
	private Point location = new Point();
	
	/**
	 * ���εĴ�С
	 */
	private Dimension size = new Dimension();

	/**
	 * ��þ��εĺ����
	 * @return
	 */
	public int getX() {
		return this.location.getX();
	}

	/**
	 * ��þ��ε������
	 * @param x
	 */
	public int getY() {
		return this.location.getY();
	}

	/**
	 * ��þ��εĿ��
	 * @return
	 */
	public int getWidth() {
		return this.size.getWidth();
	}

	/**
	 * ��þ��εĸ߶�
	 * @return
	 */
	public int getHeight() {
		return this.size.getHeight();
	}

	/**
	 * ���þ��εĺ����
	 * @param x
	 */
	public void setX(int x) {
		this.location.setX(x);
	}

	/**
	 * ���þ��ε������
	 * @param y
	 */
	public void setY(int y) {
		this.location.setY(y);
	}

	/**
	 * ���ú������
	 */
	public void setLocation(int x, int y){
		this.location.setLocation(x, y);
	}
	
	/**
	 * ���ô�С
	 * @param width
	 * @param height
	 */
	public void setSize(int width, int height){
		this.size.setWidth(width);
		this.size.setHeight(height);
	}
}
